package logic

import (
	"context"
	"good/models/mysql"

	"good/goodrpc/goodrpc"
	"good/goodrpc/internal/svc"

	"github.com/zeromicro/go-zero/core/logx"
)

type SpeakListLogic struct {
	ctx    context.Context
	svcCtx *svc.ServiceContext
	logx.Logger
}

func NewSpeakListLogic(ctx context.Context, svcCtx *svc.ServiceContext) *SpeakListLogic {
	return &SpeakListLogic{
		ctx:    ctx,
		svcCtx: svcCtx,
		Logger: logx.WithContext(ctx),
	}
}

func (l *SpeakListLogic) SpeakList(in *goodrpc.SpeakListRequest) (*goodrpc.SpeakListResponse, error) {
	// todo: add your logic here and delete this line
	var speak []mysql.Speak
	mysql.DB.Debug().Find(&speak)

	return &goodrpc.SpeakListResponse{
		List: nil,
	}, nil
}
